﻿using Mengsk.ProxyDelivery.App.Domain;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;

namespace Mengsk.ProxyDelivery.App.UI.Goods
{
    class ColorTypeVM : DependencyObject
    {
        public static readonly DependencyProperty IsCheckedProperty = DependencyProperty.Register("IsChecked", typeof(bool), typeof(ColorTypeVM));
        public static readonly DependencyProperty TitleProperty = DependencyProperty.Register("Title", typeof(string), typeof(ColorTypeVM));

        public bool IsChecked { get { return (bool)this.GetValue(IsCheckedProperty); } set { this.SetValue(IsCheckedProperty, value); } }

        public string Title { get { return (string)this.GetValue(TitleProperty); } set { this.SetValue(TitleProperty, value); } }

        public ColorType Source { get; set; }

        public ColorTypeVM(ColorType colorType, bool isChecked)
        {
            this.Source = colorType;
            this.IsChecked = isChecked;
            this.Title = colorType.Name;
        }
    }
}
